package com.xiaoyudeguang.context;

import org.springframework.context.ApplicationContext;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.stereotype.Component;

/**
 * @author 赵光
 */
@Component
@ComponentScan("com.xiaoyudeguang")
public class SpringContext {

    private static ApplicationContext applicationContext;

    public SpringContext(ApplicationContext applicationContext) {
        SpringContext.applicationContext = applicationContext;
    }

    public static ApplicationContext getContext() {
        return applicationContext;
    }

}
